home *** CD-ROM | disk | FTP | other *** search
/ Otherware / Otherware_1_SB_Development.iso / mac / misc / medical / mendelge.cpt / MendelGenetics / MENDELIAN GENETICS I / card_56258.txt < prev    next >
Text File  |  1989-06-13  |  9KB  |  309 lines

  1. -- card: 56258 from stack: in
  2. -- bmap block id: 26498
  3. -- flags: 0000
  4. -- background id: 2665
  5. -- name: 
  6.  
  7.  
  8. -- part 1 (field)
  9. -- low flags: 00
  10. -- high flags: 0002
  11. -- rect: left=275 top=225 right=246 bottom=325
  12. -- title width / last selected line: 0
  13. -- icon id / first selected line: 0 / 0
  14. -- text alignment: 0
  15. -- font id: 3
  16. -- text size: 12
  17. -- style flags: 0
  18. -- line height: 16
  19. -- part name: P
  20.  
  21.  
  22. -- part 2 (field)
  23. -- low flags: 00
  24. -- high flags: 0002
  25. -- rect: left=335 top=225 right=246 bottom=385
  26. -- title width / last selected line: 0
  27. -- icon id / first selected line: 0 / 0
  28. -- text alignment: 0
  29. -- font id: 3
  30. -- text size: 12
  31. -- style flags: 0
  32. -- line height: 16
  33. -- part name: Q
  34.  
  35.  
  36. -- part 3 (field)
  37. -- low flags: 00
  38. -- high flags: 0002
  39. -- rect: left=394 top=225 right=246 bottom=444
  40. -- title width / last selected line: 0
  41. -- icon id / first selected line: 0 / 0
  42. -- text alignment: 0
  43. -- font id: 3
  44. -- text size: 12
  45. -- style flags: 0
  46. -- line height: 16
  47. -- part name: S
  48.  
  49.  
  50. -- part 4 (field)
  51. -- low flags: 00
  52. -- high flags: 0002
  53. -- rect: left=275 top=272 right=293 bottom=325
  54. -- title width / last selected line: 0
  55. -- icon id / first selected line: 0 / 0
  56. -- text alignment: 0
  57. -- font id: 3
  58. -- text size: 12
  59. -- style flags: 0
  60. -- line height: 16
  61. -- part name: PP
  62.  
  63.  
  64. -- part 5 (field)
  65. -- low flags: 00
  66. -- high flags: 0002
  67. -- rect: left=336 top=272 right=293 bottom=386
  68. -- title width / last selected line: 0
  69. -- icon id / first selected line: 0 / 0
  70. -- text alignment: 0
  71. -- font id: 3
  72. -- text size: 12
  73. -- style flags: 0
  74. -- line height: 16
  75. -- part name: PQ
  76.  
  77.  
  78. -- part 6 (field)
  79. -- low flags: 00
  80. -- high flags: 0002
  81. -- rect: left=395 top=272 right=293 bottom=445
  82. -- title width / last selected line: 0
  83. -- icon id / first selected line: 0 / 0
  84. -- text alignment: 0
  85. -- font id: 3
  86. -- text size: 12
  87. -- style flags: 0
  88. -- line height: 16
  89. -- part name: QQ
  90.  
  91.  
  92. -- part 7 (field)
  93. -- low flags: 00
  94. -- high flags: 0002
  95. -- rect: left=454 top=272 right=293 bottom=504
  96. -- title width / last selected line: 0
  97. -- icon id / first selected line: 0 / 0
  98. -- text alignment: 0
  99. -- font id: 3
  100. -- text size: 12
  101. -- style flags: 0
  102. -- line height: 16
  103. -- part name: GEN
  104.  
  105.  
  106. -- part 8 (button)
  107. -- low flags: 00
  108. -- high flags: 8003
  109. -- rect: left=451 top=225 right=245 bottom=504
  110. -- title width / last selected line: 0
  111. -- icon id / first selected line: 0 / 0
  112. -- text alignment: 1
  113. -- font id: 0
  114. -- text size: 12
  115. -- style flags: 0
  116. -- line height: 16
  117. -- part name: RUN
  118. ----- HyperTalk script -----
  119. on mouseUp
  120.   REPEAT 120 TIMES
  121.     GLOBAL SUM
  122.     GLOBAL INTP
  123.     GLOBAL INTQ
  124.     GLOBAL GENT
  125.     GLOBAL IT
  126.     PUT THE VALUE OF ((CARD FIELD P)^2) INTO CARD FIELD PP
  127.     PUT THE VALUE OF (2*(CARD FIELD P)*(CARD FIELD Q)) INTO CARD FIELD PQ
  128.     PUT THE VALUE OF (((CARD FIELD Q)^2) * (1 - CARD FIELD S)) INTO CARD FIELD QQ
  129.     PUT THE VALUE OF (CARD FIELD PP + CARD FIELD PQ + CARD FIELD QQ) INTO SUM
  130.     PUT THE VALUE OF (CARD FIELD PP + (CARD FIELD P * CARD FIELD Q)) / SUM INTO INTP
  131.     PUT THE VALUE OF (CARD FIELD QQ + (CARD FIELD P * CARD FIELD Q)) / SUM INTO INTQ
  132.     PUT THE VALUE OF INTP INTO CARD FIELD P
  133.     PUT THE VALUE OF INTQ INTO CARD FIELD Q
  134.     ADD 1 TO CARD FIELD GEN
  135.     PUT THE VALUE OF CARD FIELD GEN INTO GENT
  136.     CHOOSE PENCIL TOOL
  137.     SET LINESIZE TO 1
  138.     set the numberFormat to "000"
  139.     PUT (200 - (200 * (THE VALUE OF CARD FIELD PP * .9))) INTO IT
  140.     CLICK AT (300 + GENT),trunc (IT)
  141.     PUT (200 - (200 *  (THE VALUE OF CARD FIELD PQ * .9))) INTO IT
  142.     CLICK AT (300 + GENT),trunc (IT)
  143.     PUT (200 - (200 * (THE VALUE OF CARD FIELD QQ * .9))) INTO IT
  144.     CLICK AT (300 + GENT),trunc (IT)
  145.     set the numberFormat to ".0000"
  146.   END REPEAT
  147.   CHOOSE BROWSE TOOL
  148. end mouseUp
  149.  
  150.  
  151.  
  152. -- part 9 (button)
  153. -- low flags: 00
  154. -- high flags: 8003
  155. -- rect: left=408 top=317 right=339 bottom=508
  156. -- title width / last selected line: 0
  157. -- icon id / first selected line: 0 / 0
  158. -- text alignment: 1
  159. -- font id: 0
  160. -- text size: 12
  161. -- style flags: 0
  162. -- line height: 16
  163. -- part name: CLEAR
  164. ----- HyperTalk script -----
  165. on mouseUp
  166.   DELETE LINE 1 OF CARD FIELD P
  167.   DELETE LINE 1 OF CARD FIELD Q
  168.   DELETE LINE 1 OF CARD FIELD S
  169.   DELETE LINE 1 OF CARD FIELD PP
  170.   DELETE LINE 1 OF CARD FIELD PQ
  171.   DELETE LINE 1 OF CARD FIELD QQ
  172.   DELETE LINE 1 OF CARD FIELD GEN
  173.   choose select tool
  174.   drag from 300,21 to 507,200
  175.   doMenu "Pickup"
  176.   choose browse tool
  177.   GET THE LOCATION OF CARD FIELD P
  178.   CLICK AT IT
  179. end mouseUp
  180.  
  181.  
  182.  
  183. -- part 11 (button)
  184. -- low flags: 00
  185. -- high flags: 8003
  186. -- rect: left=205 top=315 right=337 bottom=256
  187. -- title width / last selected line: 0
  188. -- icon id / first selected line: 0 / 0
  189. -- text alignment: 1
  190. -- font id: 0
  191. -- text size: 12
  192. -- style flags: 0
  193. -- line height: 16
  194. -- part name: NEXT
  195. ----- HyperTalk script -----
  196. on mouseUp
  197.   go to next card
  198. end mouseUp
  199.  
  200.  
  201.  
  202. -- part 12 (button)
  203. -- low flags: 00
  204. -- high flags: 8003
  205. -- rect: left=149 top=314 right=337 bottom=199
  206. -- title width / last selected line: 0
  207. -- icon id / first selected line: 0 / 0
  208. -- text alignment: 1
  209. -- font id: 0
  210. -- text size: 12
  211. -- style flags: 0
  212. -- line height: 16
  213. -- part name: PREV.
  214. ----- HyperTalk script -----
  215. on mouseUp
  216.   go back
  217. end mouseUp
  218.  
  219.  
  220.  
  221. -- part 14 (button)
  222. -- low flags: 00
  223. -- high flags: 8003
  224. -- rect: left=273 top=316 right=338 bottom=373
  225. -- title width / last selected line: 0
  226. -- icon id / first selected line: 0 / 0
  227. -- text alignment: 1
  228. -- font id: 0
  229. -- text size: 12
  230. -- style flags: 0
  231. -- line height: 16
  232. -- part name: COPY GRAPH
  233. ----- HyperTalk script -----
  234. on mouseUp
  235.   choose select tool
  236.   drag from 260,18 to 508,219
  237.   doMenu "Copy Picture"
  238.   doMenu "Scrapbook"
  239.   doMenu "Paste Picture"
  240.   choose browse tool
  241. end mouseUp
  242.  
  243.  
  244.  
  245. -- part contents for background part 1
  246. ----- text -----
  247. HARDY-WEINBERG
  248.  
  249. -- part contents for background part 2
  250. ----- text -----
  251. This card executes the Hardy-Weinberg function. Before making a run click on the CLEAR button. You will be prompted to enter a value in the box marked P. It should be a decimal value representing the frequency of the dominant gene in the population. Hit the TAB key after entering the P value and you will be prompted to enter a value for Q, the recessive gene. Note that the sum of P + Q = 1 therefore if you enter .4 for the value of P then Q must be .6. Hit the TAB key and you will be prompted to enter a selection coefficient. If the homozygous recessive gene is 100% lethal, then enter 1. If only half of the individuals with the homozygous condition die, then enter .5. If the gene in question kills no individuals, then enter 0. Click on the RUN button. The changing frequency of the homozygous dominant phenotype, (PP) will appear in the window marked (PP). The heterozygote phenotypes will appear in the window marked (PQ) and the homozygous recessive phenotype frequencies will appear in the window marked (QQ). The frequency of each phenotype will be simultaneously tracked on the graph above. If you wish to change the selection coefficient at some point in the run, simultaneously hit             [CONTROL] and the [.] keys. Get back into the BROWSE mode and then simply move the cursor to the window marked S and click. Delete the value therein and enter your new value. For starters, you can experiment with the following data:
  252.  
  253.   TRIAL     P freq.    Q freq.      S
  254.  
  255.     1.        .6            .4           0
  256.     2.        .6            .4          .2
  257.     3.        .6            .4          .4
  258.     4.        .6            .4          .8
  259.     5.        .6            .4           1
  260.     6.        .9            .1          .4
  261.     7.        .1            .9          .4
  262.  
  263. From the data obtained in these runs, you can answer the following questions. (Note... use the disk. Simply click just to the right of the answer colon and begin typing.
  264.  
  265. 1. At what point in the course of this population's evolution was selection most effective?
  266.    ANSWER:
  267.  
  268. 2. Which is more effective in keeping recessive genes in a population, a low selection coefficient or a high starting frequency for the recessive gene?  Does it matter?
  269.     ANSWER:
  270.  
  271. 3. No matter how large the selection coefficient, recessive genes are never completely eliminated from the population... thus the asymptotic curves seen in the graph. Where are the recessive genes stored or kept in order for them to keep appearing generation after generation?
  272.     ANSWER:
  273.  
  274. 4. No matter how low the recessive gene frequency in a population, if it is not being selected against by any factor, what will be the frequency of such a gene 25 or so generations into the future.
  275.     ANSWER:
  276.  
  277. When you have completed this card, flip to the next card for a consideration of random sampling errors.
  278.  
  279. -- part contents for background part 8
  280. ----- text -----
  281. 59
  282.  
  283. -- part contents for card part 1
  284. ----- text -----
  285. .8996
  286.  
  287. -- part contents for card part 2
  288. ----- text -----
  289. .1003
  290.  
  291. -- part contents for card part 4
  292. ----- text -----
  293. .8077
  294.  
  295. -- part contents for card part 3
  296. ----- text -----
  297. .1
  298.  
  299. -- part contents for card part 5
  300. ----- text -----
  301. .1821
  302.  
  303. -- part contents for card part 6
  304. ----- text -----
  305. .0092
  306.  
  307. -- part contents for card part 7
  308. ----- text -----
  309. 120.0000